package controller_join

import (
	service_join "hft/Http/Services/join"
	types_join "hft/Http/Services/join/types"
	utils "hft/Http/Utils"

	"github.com/gin-gonic/gin"
)

type Join struct{}

// 获取加盟合作列表
func (*Join) List(c *gin.Context) {
	var paginate *types_join.JoinParams
	if err := c.ShouldBindJSON(&paginate); err != nil {
		utils.FailWithMessage("结构体解析失败", c)
	} else {
		data := service_join.JoinService.List(paginate)
		utils.OkWithData(data, c)
	}

}

var JoinController = new(Join)
